<template>
    <div class="box">
      <div v-for="(item , index) in items" :key="index">
        <navigator>
          <div class="strategy_box">
            <img :src="item.imgSrc" :alt="item.name"  mode="widthFix">
            <p>{{item.name}}</p>
          </div>
          <div class="strategy_introduce">
            <p>{{item.content}}</p>
          </div>
        </navigator>
      </div>
    </div>
</template>

<script>
  export default {
    name: "index",
    data(){
      return{
        items:[
          {name:'田园风光',imgSrc:'http://wx.v4.yunyouyuanfang.com/travel_v4//9d16530903a54814b36d0b8df74d3047.jpg',content:'十大砂进口拉萨的'},
          {name:'田园风光',imgSrc:'http://wx.v4.yunyouyuanfang.com/travel_v4//9d16530903a54814b36d0b8df74d3047.jpg'}
        ]
      }
    }
  };
</script>

<style lang="scss" scoped>
  .box > div {
    padding: 30rpx 30rpx 0;
  }
  navigator {
    .strategy_introduce {
      color: #787878;
      width: 100%;
      margin: auto;
      padding: .5rem;
      box-sizing: border-box;
      line-height: 2;
      font-size: 3.4vw;
      text-overflow: ellipsis;
      white-space: nowrap;
      overflow: hidden;
    }
    .strategy_box{
      position: relative;
      p {
        position: absolute;
        left: 0;
        bottom: 0;
        width: 100%;
        background: rgba(152,117,53,0.5);
        line-height: 72rpx;
        color: #fff;
        font-size: 3.6vw;
        padding-left: 12rpx;
        box-sizing: border-box;
      }
    }
    .strategy_introduce {
      color: #787878;
      width: 100%;
      margin: auto;
      padding: 12rpx;
      box-sizing: border-box;
      line-height: 2;
      font-size: 3.4vw;
      text-overflow: ellipsis;
      white-space: nowrap;
      overflow: hidden;
      p{
        width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
      }
    }
  }
</style>
